package com.hshoesmall.demo.mapper;

import com.hshoesmall.demo.model.entity.ShoesByPage;
import org.apache.ibatis.annotations.Select;


import java.util.List;

public interface ShoesByPageMapper {



    @Select("select sid,stid,sbid,simage,sprices,sdiscount,sname,bname,tname from ranks " +
            "join brands on ranks.sbid = brands.bid " +
            "join types on ranks.stid = types.tid " +
            "limit #{offset},#{pageSize}")
    List<ShoesByPage> findShoesListByPage(Integer offset, Integer pageSize,Integer[] sbids, Integer[] stids, Integer[] sizeids, Integer[] scids, String[] sgenders);

    @Select("select count(sid) from ranks")
    Integer countShoes();
}
